<?php

require '../../config.php';
 
  
$result = mysql_query('select * from provincias',$conexion);  
 
if(mysql_num_rows($result)>0)
{  
			$data = array();
			while ($row = mysql_fetch_array($result))
			 {
			    $data[] = $row['idprovincias'];
    			$data[] = $row['PROVINCIA'];
			}
			echo json_encode($data);		
}
else 
{
	echo("0");
}
?> 